/**
 * Created by user on 2018/4/16.
 */
import { message } from 'antd';

import Request from './Request'
class GlobalAlert {
  success(text) {
    message.destroy()
    message.success(text)
  }
  error(text) {
    message.destroy()
    message.error(text)
  }

  warning(text) {
    message.destroy()
    message.warning(text)
  }
}

module.exports = {
  Request,
  GlobalAlert: new GlobalAlert()
}
